#include "poscartotar.h"
#include <math.h>

PosCarToTar::PosCarToTar()
{

}

PosCarToTar::CarToTar(double x_car, double y_car, double l0, double l1, int a, int b, double &x_tar, double &y_tar)
{
    a = 180 - a;
    x_tar = x_car+l0*sin(a)+l1*cos(a-b);
    y_tar = y_car+l0*cos(a)+l1*sin(a-b);
}
